package com.lyf.shop.dao;

import com.lyf.shop.entity.Address;

import java.sql.SQLException;
import java.util.List;

public interface AddressDao {
    //获取地址数据
    List<Address> getAddressByUid(int uid) throws SQLException;
    //新增地址
    int insertAddr(Address address) throws SQLException;
    //删除地址
    int delAddr(int aid) throws SQLException;
    //修改地址
    int updateAddr(Address address) throws SQLException;
    //设置默认值 直接代表我们要设置为默认地址的数据
    int changeAddrToDefault(int aid) throws SQLException;
    //uid为了防止我们修改到其他用户的地址数据
    int changeAddrToCommons(int aid,int uid ) throws  SQLException;
}
